Skip to content

Feat flashmode for ESP8266#511

Draft
unlogisch04 wants to merge 13 commits intomainfrom
feat_flashmode
Draft

Feat flashmode for ESP8266#511
unlogisch04 wants to merge 13 commits intomainfrom
feat_flashmode

Conversation

@unlogisch04
Copy link
Copy Markdown
Contributor

@unlogisch04 unlogisch04 commented Jan 11, 2026

On Official Slime HW it is not possible to flash them just over USB when they are in a boot loop.
They are based from ESP8266.
Left ESP32* out of loop as they either have a HW solution to put them into Flash Mode or use USB JTag on the chip.
Target is, that there is a fail safe at begin of the program so it goes into flash mode if it reboots more than 3 times after a crash. For ESP32 it is directly after a crash. For HW with softpower solution (gorbits as example) the code in init has maybe to be changed, so a reboot with a button press is still possible.

Current Status is:

  • A safe mode shell
  • Boot Prompt with Infos from Flash
  • Small Serial command set:
    • FRST - Factory Reset, cleans the config file and WiFi credentials (useful by crashes to wrong configs)
    • SET FLASHMODE - Sets the tracker into flashmode does work on ESP8266 and ESP32-C3 )
    • REBOOT - Reboots the tracker
  • Still not able to recover from updates that have been interrupted by power off at the wrong time

Tasks:

  • Needs to be checked if this constructor runs rly before all other constructors.
  • Testing with official Slimes
  • Testing that no breaks for ESP32 variants.
  • Lint

@unlogisch04
Copy link
Copy Markdown
Contributor Author

Target is, that there is a fail safe at begin of the program so it goes into flash mode if it reboots more than 3 times (for esp8266) and for ESP32 at the first reboot.

Currently it goes directly into flashmode, or stops the execution to wait for jtag. (Or to give the user chance to upload the firmware on esp32c3)
Not sure if it would be better to present a cmd line, where you could

  1. factory reset
  2. set the tracker to flash mode
  3. delete some config files

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant